<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%> 
  <div class="box-body">
    <ul class="todo-list ui-sortable">
		<c:if test="${empty list}">
			<li style="height:209px"></li>
		</c:if>
      	<c:forEach items="${list}" var="todo">
	      	<li>
	            <span class="handle ui-sortable-handle">
		            <i class="fa fa-ellipsis-v"></i>
		            <i class="fa fa-ellipsis-v"></i>
	            </span>
		        <span class="text">
			        <c:if test="${fn:length(todo.todoTitle) > 20}" var="resultTest">
						<a target="_blank" title="${todo.todoTitle}" style="cursor: pointer;color: #444;" href="${pageContext.request.contextPath}/jbpmService/work/getWorkByTodoId?todoId=${todo.todoId }">
							${fn:substring(todo.todoTitle,0,20) }...
						</a>
					</c:if>
					<c:if test="${!resultTest}">
						<a target="_blank" title="${todo.todoTitle}" style="cursor: pointer;color: #444;" href="${pageContext.request.contextPath}/jbpmService/work/getWorkByTodoId?todoId=${todo.todoId }">
							${todo.todoTitle}
						</a>
					</c:if>
		        </span>
		        <small class="label label-primary"><i class="fa fa-clock-o"></i><fmt:formatDate value="${todo.arriveTime }" pattern="yyyy-MM-dd HH:mm:ss" /></small>
	      	</li>
      	</c:forEach>
      	<c:if test="${fn:length(list) > 0 && fn:length(list) < 5}">
			<c:forEach begin="0" end="${4 - fn:length(list) }" >
		      	<li>
			        <span class="text"></span>
		      	</li>
	      	</c:forEach>
		</c:if>
    </ul>
  </div>
  <!-- /.box-body -->
    <script type="text/javascript">
    </script>